package model

import "time"

//资源模型
type Resource struct {
	Id       int       `xorm:"pk"`
	Category int8      `xorm:"tinyint(4) notnull" form:"category" title:"资源类型"`
	Level    int8      `xorm:"tinyint(4) notnull" form:"level" title:"资源层级"`
	ParentId int       `xorm:"int(11) notnull" form:"parentid" title:"父级ID"`
	Title    string    `xorm:"varchar(200) notnull" form:"title" binding:"required" title:"资源名称"`
	Url      string    `xorm:"varchar(200) notnull" form:"resourceurl" binding:"required" title:"资源URL"`
	Remark   string    `xorm:"varchar(200) notnull" form:"remark" title:"备注"`
	Icon     string    `xorm:"varchar(50) " form:"resourceicon" binding:"required" title:"资源图标"`
	Sortnum  int       `xorm:"smallint(6) notnull" form:"sortnum" title:"排序"`
	Created  time.Time `xorm:"created"`
	Updated  time.Time `xorm:"updated"`
}
